package com.bonuo.crm.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

@Data
@AllArgsConstructor
@NoArgsConstructor
@EqualsAndHashCode(callSuper = true)
public class Payment extends BaseEntity {
    /** 项目开票ID */
    private Integer id;

    /** 项目ID */
    private Integer projectId;

    /** 项目名称 */
    private String projectName;

    /** 用户ID */
    private Integer userId;

    /** 部门ID */
    private Integer deptId;

    /** 回款属性 */
    private String type;

    /** 回款金额 */
    @Excel(name = "回款金额")
    private BigDecimal paymentAmount;

    /** 回款比例 */
    @Excel(name = "回款比例")
    private BigDecimal paymentRatio;

    /** 回款日期 */
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "回款日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date paymentDate;

    /** 质保金到期日期 */
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "回款日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date expireDate;

    /** 备注 */
    @Excel(name = "备注")
    private String remark;
}
